home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ WinNT Max User.xpl < prev    next >
Text File  |  2002-10-31  |  1KB  |  56 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="2"
  3. "COUNT"="1"
  4. "UIPATH"="Network\Server\File/Print Serving"
  5. "NAME"="Max User Connections"
  6. "VERSION"="1.16"
  7. "OSVERSION"="0101011"
  8. "LANGUAGE"="VBScript"
  9. "TEXT 1"="Max. Connects"
  10. "DESCRIPTION 1"="Use this plug-in to change the maximum count of users that are allowed to connect to this machine at a time."
  11. "DESCRIPTION 2"="This setting is useful if the server is slow."
  12. "DESCRIPTION 3"="To restore the original settings, clear the field."
  13. "AUTHOR"="Xteq Systems"
  14. "CONTACTURL"="http://www.xteq.com"
  15. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  16. "COMMENT 1"=" "
  17.  
  18.  
  19. sP="HKLM\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters\Users"
  20. Sub Plugin_Initialize 
  21.     i=RegReadValue(sP)
  22.     SetUIElement 1,i
  23. End Sub
  24.  
  25. Sub Plugin_CheckData(ElementIndex)
  26. End Sub
  27.  
  28. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  29.  i=GetUIElement(1)
  30.  
  31.  if i="" then
  32.     'Delete Value   
  33.  
  34.     i=RegReadValue(sP)
  35.     if not isEmpty(i) then 
  36.        Call RegDeleteValue(sP)
  37.     end if
  38.  
  39.  else
  40.     'Set Value
  41.  
  42.     if IsNumeric(i) then
  43.        Call RegWriteValue(sP,i,2)
  44.        Call Restart
  45.     else
  46.         Call MsgError("Please enter a valid numeric value.")
  47.     end if
  48.  
  49.  end if
  50.   
  51.  
  52. End Sub
  53.  
  54. Sub Plugin_Terminate 
  55. End Sub
  56.